import request from '@/utils/request'

// 查询统计总列表
export function listStatistic(query) {
  return request({
    url: '/consumer/statistic/list',
    method: 'get',
    params: query
  })
}

// 查询统计总详细
export function getStatistic(statisticId) {
  return request({
    url: '/consumer/statistic/' + statisticId,
    method: 'get'
  })
}

// 新增统计总
export function addStatistic(data) {
  return request({
    url: '/consumer/statistic',
    method: 'post',
    data: data
  })
}

// 修改统计总
export function updateStatistic(data) {
  return request({
    url: '/consumer/statistic',
    method: 'put',
    data: data
  })
}

// 删除统计总
export function delStatistic(statisticId) {
  return request({
    url: '/consumer/statistic/' + statisticId,
    method: 'delete'
  })
}

//获取统计总数据
export function getStatisticData(query) {
  return request({
    url: 'api/statistic/queryStatisticCard',
    method: 'get',
    params: query
  })
}
